package cn.com.dhcc.turbo.entity.registry.wapper;

import cn.com.dhcc.turbo.entity.registry.FtpUser;
import org.springframework.jdbc.core.RowMapper;

import java.sql.ResultSet;
import java.sql.SQLException;

public class FtpUserRowWapper implements RowMapper<FtpUser> {
	@Override
	public FtpUser mapRow(ResultSet rs, int rowNum) throws SQLException {
		FtpUser vo = new FtpUser();
		vo.setUserid(rs.getString("userid"));
		vo.setUserpassword(rs.getString("userpassword"));
		vo.setHomedirectory(rs.getString("homedirectory"));
        vo.setEnableflag(rs.getInt("enableflag"));
        vo.setWritepermission(rs.getInt("writepermission"));
        vo.setIdletime(rs.getLong("idletime"));
        vo.setUploadrate(rs.getLong("uploadrate"));
        vo.setDownloadrate(rs.getLong("downloadrate"));
        vo.setMaxloginnumber(rs.getLong("maxloginnumber"));
        vo.setMaxloginperip(rs.getLong("maxloginperip"));
		return vo;
	}
}
